﻿Imports System.Xml.Serialization

'http://www.blackwasp.co.uk/XMLArrays.aspx -- serializing and deserializing
<Serializable()> _
Public Class control

    Private _controlId As Integer
    <XmlAttribute(attributeName:="controlID")> _
    Public Overridable Property ControlId() As Integer
        Get
            Return _controlId
        End Get
        Set(ByVal value As Integer)
            _controlId = value
        End Set
    End Property

    Private _controlTypeID As String
    <XmlAttribute(attributeName:="controlTypeID")> _
    Public Overridable Property ControlTypeID() As String
        Get
            Return _controlTypeID
        End Get
        Set(ByVal value As String)
            _controlTypeID = value
        End Set
    End Property

    Private _isInGroup As Integer
    <XmlAttribute(attributeName:="isInGroup")> _
    Public Overridable Property isInGroup() As Integer
        Get
            Return _isInGroup
        End Get
        Set(ByVal value As Integer)
            _isInGroup = value
        End Set
    End Property

    Private _measuredW As Integer
    <XmlAttribute(attributeName:="measuredW")> _
    Public Overridable Property measuredW() As Integer
        Get
            Return _measuredW
        End Get
        Set(ByVal value As Integer)
            _measuredW = value
        End Set
    End Property

    Private _measuredH As Integer
    <XmlAttribute(attributeName:="measuredH")> _
    Public Overridable Property measuredH() As Integer
        Get
            Return _measuredH
        End Get
        Set(ByVal value As Integer)
            _measuredH = value
        End Set
    End Property

    Private _controlProperties As controlProperties
    <XmlElement("controlProperties")> _
    Public Overridable Property controlProperties() As controlProperties
        Get
            Return _controlProperties
        End Get
        Set(ByVal value As controlProperties)
            _controlProperties = value
        End Set
    End Property

    Private _x As Integer
    <XmlAttribute(attributeName:="x")> _
    Public Overridable Property X() As Integer
        Get
            Return _x
        End Get
        Set(ByVal value As Integer)
            _x = value
        End Set
    End Property

    Private _y As Integer
    <XmlAttribute(attributeName:="y")> _
    Public Overridable Property Y() As Integer
        Get
            Return _y
        End Get
        Set(ByVal value As Integer)
            _y = value
        End Set
    End Property

End Class
